#ifndef SESSION_LIST_WIDGET_H
#define SESSION_LIST_WIDGET_H

#include <QtGui/QListWidget>

class QToolButton;
class QLineEdit;

class ListWidget : public QListWidget
{
	Q_OBJECT
	signals:
		void openSession(const QString& name);
		void startNewSession();
		void saveSessionAs(const QString& name);
		void removeSession(const QString& name);
	public:
		ListWidget();
		~ListWidget();
	private slots:
		void showInputLine();
		void textChanged(const QString& text);
		void emitSignalToSaveSessionAs();
		void emitSignalToOpenSession();
		void emitSignalToRemoveSession();
	private:
		QPalette redPalette;
		QPalette defaultPalette;
		
		QWidget *inputLine;
		
		QLineEdit *lineEdit;
		QToolButton *closeButton;
		QToolButton *saveButton;
		
		QToolButton *openSessionButton;
		QToolButton *newSessionButton;
		QToolButton *saveAsSessionButton;
		QToolButton *removeSessionButton;
};


#endif
